directory_exists

This function checks whether a given directory exists.

bool directory_exists(string directory_name)

Parameters:
directory_name
The name of the directory to search for.

Return value:
true if the directory exists, false otherwise.

Remarks:
This function works with both absolute and relative paths.

Please note that the path may not end in a trailing slash or backslash, and may not contain wildcards.

Example:
// Check if the Windows directory exists.

void main()
{
if(directory_exists("C:\\windows"))
{
alert("Information", "Windows directory exists. I'd be slightly concerned if it didn't.");
}
else
{
alert("Oops", "You broke Windows! Hang on though, how on earth is it running?");
}
}